package com.echo.blog.business.music.model;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;

import java.io.Serializable;
import java.util.Date;

/**
 * <p>
 * 音乐主表
 * </p>
 *
 * @author chentl123
 * @since 2019-07-11
 */
@TableName("echo_business_music")
public class Music extends Model<Music> {

    private static final long serialVersionUID = 1L;

    public Music() {
    }

    public Music(String name, String artist, String url, String cover, String lrc, String theme, Integer createby) {
        this.name = name;
        this.artist = artist;
        this.url = url;
        this.cover = cover;
        this.lrc = lrc;
        this.theme = theme;
        this.createby = createby;
    }

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;
    /**
     * 音乐名
     */
    private String name;
    /**
     * 艺术家
     */
    private String artist;
    /**
     * 地址
     */
    private String url;
    /**
     * 封面
     */
    private String cover;
    /**
     * 歌词文件地址
     */
    private String lrc;
    /**
     * 主题
     */
    private String theme;
    /**
     * 创建人
     */
    private Integer createby;
    /**
     * 创建时间
     */
    private Date createTime;


    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getArtist() {
        return artist;
    }

    public void setArtist(String artist) {
        this.artist = artist;
    }

    public String getUrl() {
        return url;
    }

    public void setUrl(String url) {
        this.url = url;
    }

    public String getCover() {
        return cover;
    }

    public void setCover(String cover) {
        this.cover = cover;
    }

    public String getLrc() {
        return lrc;
    }

    public void setLrc(String lrc) {
        this.lrc = lrc;
    }

    public String getTheme() {
        return theme;
    }

    public void setTheme(String theme) {
        this.theme = theme;
    }

    public Integer getCreateby() {
        return createby;
    }

    public void setCreateby(Integer createby) {
        this.createby = createby;
    }

    public Date getCreateTime() {
        return createTime;
    }

    public void setCreateTime(Date createTime) {
        this.createTime = createTime;
    }

    @Override
    protected Serializable pkVal() {
        return this.id;
    }

    @Override
    public String toString() {
        return "Music{" +
                ", id=" + id +
                ", name=" + name +
                ", artist=" + artist +
                ", url=" + url +
                ", cover=" + cover +
                ", lrc=" + lrc +
                ", theme=" + theme +
                ", createby=" + createby +
                ", createTime=" + createTime +
                "}";
    }
}
